﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Utils.Common
{
   public  class CalculateDate
    {





        private static string GetYear(int year)
        {

            string code = string.Empty;
            switch (year)
            {
                case 2023:code = "3";break;
                case 2024: code = "4"; break;
                case 2025: code = "5"; break;
                case 2026: code = "6"; break;
                case 2027: code = "7"; break;
                case 2028: code = "8"; break;
                case 2029: code = "9"; break;
                case 2030: code = "0"; break;
                case 2031: code = "1"; break;
                case 2032: code = "2"; break;
            }
            return code;
        }

        private static string GetMonth(int month)
        {

            string code = string.Empty;
            switch (month)
            {
                case 1: code = "M"; break;
                case 2: code = "T"; break;
                case 3: code = "S"; break;
                case 4: code = "U"; break;
                case 5: code = "J"; break;
                case 6: code = "K"; break;
                case 7: code = "G"; break;
                case 8: code = "H"; break;
                case 9: code = "P"; break;
                case 10: code = "N"; break;
                case 11: code = "E"; break;
                case 12: code = "X"; break;
            }
            return code;
        }


        public static string GetDate()
        {
            return GetYear(DateTime.Now.Year) + GetMonth(DateTime.Now.Month) + DateTime.Now.Day.ToString().PadLeft(2,'0');
        }
    }


}
